Newer
Older
EARS-LINUX / KIOSK setup / kiosk-start.sh
#!/bin/bash
LOG_DIR="$HOME/kiosk/logs"
mkdir -p "$LOG_DIR"

VT=$(fgconsole 2>/dev/null) || {
    echo "Not on a text console. Press Ctrl+Alt+F3, log in there, and run this again."
    exit 1
}

echo "Starting kiosk on VT $VT. Ctrl+Alt+F7 returns to the desktop."
sleep 1

startx "$HOME/kiosk/kiosk-session.sh" -- :1 "vt${VT}" -keeptty -nocursor \
    >> "$LOG_DIR/startx.log" 2>&1

echo "Kiosk session ended."